package com.ssy.lingxi.purchase.api.enums.common;


import com.ssy.lingxi.common.language.LanguageHolder;

/**
 * 排序状态 - enum
 * @author fhj
 * @date 2021/07/30
 * @version 2.0.0
 */
public enum OrderTypeEnum {

    INTEGRAL_DESC(1, "信用积分降序"),
    INTEGRAL_ASC(2, "信用积分升序"),
    CREATE_TIME_DESC(3, "发布时间降序"),
    CREATE_TIME_ASC(4, "发布时间升序");

    private final int code;
    private final String message;

    OrderTypeEnum(int code, String message) {
        this.code = code;
        this.message = message;
    }

    public int getCode() {
        return code;
    }

    public String getMessage() {
        return LanguageHolder.getName(this.getClass(), this.code);
    }
}
